<html>
<head><title>QwiLogin Options</title>
<style type="text/css">
p, td, h1 {
  font-family: arial, sans-serif;
  font-size: 10pt;
}
h1 {
    font-size: 12pt;
}
</style>
<script type="text/javascript">

// Saves options to localStorage.
function saveOptions() {
    var options = {
        nickname: document.getElementById("nickname").value,
        channels: document.getElementById("channels").value
    };
    localStorage.options = JSON.stringify(options);
}

// Restores options from localStorage.
function restoreOptions() {
    if (!localStorage.options)
        return;
        
    var options = JSON.parse(localStorage.options);
    if (!options)
        return;
        
    if (options.nickname)
        document.getElementById("nickname").value = options.nickname;
    if (options.channels)
        document.getElementById("channels").value = options.channels;
}

</script>
</head>
<body onload="restoreOptions()">

<table border="0">

<tr>
<td colspan="2"><h1><img src="icon-32x32.png" style="vertical-align: bottom"> QwiLogin Options</h1></td>
</tr>

<tr>
<td>Nickname:</td>
<td><input type="text" id="nickname" size="20"></td>
</tr>

<tr>
<td>Channels:</td>
<td><input type="text" id="channels" size="20"></td>
</tr>

<tr>
<td></td>
<td><button onclick="saveOptions()">Save</button></td>
</tr>

</table>

<h1>About</h1>
<p>QwiLogin automatically fills in the login and channel fields<br>on the login page of webchats that use <a href="http://qwebirc.org/">qwebirc</a>.</p>
<p>Supported webchats are <a href="http://webchat.freenode.net/">Freenode</a> and <a href="http://webchat.quakenet.org/">QuakeNet</a>.</p>
<p>Copyright 2010 <a href="http://code.google.com/p/romanito/">Romain Vallet</a>.</p>
<p>QwiLogin is not supported by the qwebirc authors.</p>
<p>This Google Chrome extension has been released<br>under the terms of the <a href="http://creativecommons.org/licenses/MIT/">MIT License</a>.</p>
<p>qwebirc icon - <a href="http://meeb.org/">meeb.org</a>.</p>


</body>
</html>